<?php
/**
 * ============================================================================
 * Copyright (c) 2015-2020 贵州大师兄信息技术有限公司 All rights reserved.
 * siteַ: https://www.gzdsx.cn
 * ============================================================================
 * @author:     David Song<songdewei@163.com>
 * @version:    v1.0.0
 * ---------------------------------------------
 * Date: 2020/3/15
 * Time: 2:31 下午
 */

Route::group(['namespace' => 'H5'], function () {
    Route::get('/', 'IndexController@index');
    Route::get('canvas', 'IndexController@canvas');
    Route::get('catlog', 'CatlogController@index');
    //item
    Route::get('item/detail/{itemid}.html', 'ItemController@detail');
    Route::get('item/search', 'ItemController@search');
    //video
    Route::get('video', 'VideoController@index');
    Route::get('video/detail/{id}.html', 'VideoController@detail');
    //pages
    Route::get('page', 'PagesController@index');
    Route::get('page/{pageid}.html', 'PageController@detail');

    Route::get('post/detail/{aid}.html','PostController@detail');


    Route::group(['middleware'=>'h5.auth'],function (){
        Route::get('cart', 'CartController@index');
        //order
        Route::get('order', 'OrderController@index');
        Route::get('order/detail', 'OrderController@detail');
        Route::get('order/buynow', 'OrderController@buynow');
        Route::get('order/rate', 'OrderController@rate');
        Route::post('order/confirm', 'OrderController@confirm');
        //sold
        Route::get('sold/detail', 'SoldController@detail');
        //refund
        Route::get('refund/apply', 'RefundController@allpy');
        //user
        Route::get('user', 'UserController@index');
        Route::get('address', 'AddressController@index');
        Route::get('security', 'SecurityController@index');
        Route::get('feedback', 'FeedBackController@index');
        //live
        Route::get('live','LiveController@index');
        Route::get('live/{id}','LiveController@detail');
        //login
        Route::get('login', 'LoginController@index');
        Route::get('login/confirm', 'LoginController@confirm');
        Route::get('login/cancel', 'LoginController@cancel');
    });
});
